const RouteView = () => import('@/layout/RouteView');
// 异步路由组件加载
const AsyncComponent = __name__ => () => import(`@/pages/${__name__}`);

// 售后服务路由
const routers = [
  {
    path: '/evaluateManage',
    meta: {
      title: '评价管理',
      icon: 'el-icon-star-on'
    },
    redirect: '/evaluateManage',
    component: RouteView,
    children: [
        {
          path: '/evaluateManage/lowScoreMange',
          meta: {
            title: '低分评价管理'
          },
          redirect: '/evaluateManage/lowScoreMange',
          component: RouteView,
          children: [
            {
              path: '/evaluateManage/lowScoreMange/saleLowScoreQuery',
              meta: {
                title: '低分评价查询(销售)',
                keepAlive: true
              },
              component: AsyncComponent('evaluateManage/lowScoreMange/saleLowScoreQuery')
            },
            {
              path: '/evaluateManage/lowScoreMange/afterSaleLowScoreQuery',
              meta: {
                title: '低分评价查询(售后)',
                keepAlive: true
              },
              component: AsyncComponent('evaluateManage/lowScoreMange/afterSaleLowScoreQuery')
            }
          ]
      }
    ]
  }
]

export default routers;
